using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;
using System.Reflection;
using System.Threading;
using System.Collections.Generic;
using FSharpChess;

namespace SharpChess
{
	/// <summary>
	/// Summary description for frmMain.
	/// </summary>

	public class frmMain : System.Windows.Forms.Form
	{
        public Cursor[] m_acurPieceCursors = new Cursor[12];
        public PictureBox[,] m_picSquares;

        private System.ComponentModel.IContainer components;
        public System.Windows.Forms.ImageList imgPieces;
		public System.Windows.Forms.MainMenu mnu;
		public System.Windows.Forms.MenuItem mnuFile;
		public System.Windows.Forms.MenuItem mnuExit;
        public System.Windows.Forms.MenuItem mnuHelp;
		public System.Windows.Forms.MenuItem mnuNew;
		public System.Windows.Forms.MenuItem mnuSave;
		public System.Windows.Forms.MenuItem mnuOpen;
		public System.Windows.Forms.MenuItem mnuSep1;
		public System.Windows.Forms.MenuItem mnuUndoMove;
		public System.Windows.Forms.MenuItem mnuSep2;
		public System.Windows.Forms.ToolBar tbr;
		public System.Windows.Forms.ToolBarButton tbrNew;
		public System.Windows.Forms.ImageList imgToolMenus;
		public System.Windows.Forms.ToolBarButton tbrOpen;
		public System.Windows.Forms.ToolBarButton tbrSave;
		public System.Windows.Forms.ToolBarButton tbrSep1;
		public System.Windows.Forms.ToolBarButton tbrUndoMove;
		public System.Windows.Forms.ToolBarButton tbrSep2;
        public System.Windows.Forms.Panel pnlMain;
		public System.Windows.Forms.ListView lvwMoveHistory;
		public System.Windows.Forms.ColumnHeader lvcBlackNo;
		public System.Windows.Forms.GroupBox groupBox1;
		public System.Windows.Forms.Panel pnlEdging;
		public System.Windows.Forms.Panel panel1;
		public System.Windows.Forms.Panel panel2;
		public System.Windows.Forms.Panel panel3;
		public System.Windows.Forms.Panel panel4;
		public System.Windows.Forms.ImageList imgTiles;
		public System.Windows.Forms.MenuItem mnuRedoMove;
		public System.Windows.Forms.MenuItem mnuUndoAllMoves;
		public System.Windows.Forms.ToolBarButton tbrRedoMove;
		public System.Windows.Forms.ToolBarButton tbrUndoAllMoves;
		public System.Windows.Forms.ToolBarButton tbrRedoAllMoves;
		public System.Windows.Forms.MenuItem mnuRedoAllMoves;
        public System.Windows.Forms.MenuItem mnuShowThinking;
		public System.Windows.Forms.Label lblBlackClock;
		public System.Windows.Forms.Label lblBlackPosition;
		public System.Windows.Forms.Label lblBlackScore;
		public System.Windows.Forms.ComboBox cboIntellegenceBlack;
		public System.Windows.Forms.Label lblBlackPoints;
		public System.Windows.Forms.Label lblWhiteClock;
		public System.Windows.Forms.Label lblWhitePosition;
		public System.Windows.Forms.Label lblWhiteScore;
		public System.Windows.Forms.ComboBox cboIntellegenceWhite;
		public System.Windows.Forms.Label lblWhitePoints;
		public System.Windows.Forms.Label lblPlayerClocks;
		public System.Windows.Forms.Label label2;
		public System.Windows.Forms.Label label4;
		public System.Windows.Forms.Label label1;
		public System.Windows.Forms.Label lblPlayer;
		public System.Windows.Forms.Timer timer;
		public System.Windows.Forms.ToolBarButton tbrResumePlay;
		public System.Windows.Forms.ToolBarButton tbrPausePlay;
		public System.Windows.Forms.MenuItem mnuResumePlay;
		public System.Windows.Forms.MenuItem mnuPausePlay;
        public System.Windows.Forms.ColumnHeader lvcWhite;
		public System.Windows.Forms.ColumnHeader lvcBlack;
		public System.Windows.Forms.Label label3;
		public System.Windows.Forms.Label label5;
		public System.Windows.Forms.ToolBarButton tbrFlipBoard;
        public System.Windows.Forms.ToolBarButton tbrSep3;
		public System.Windows.Forms.Label lblGamePaused;
		public System.Windows.Forms.MenuItem mnuDifficulty;
		public System.Windows.Forms.ToolBarButton tbrMoveNow;
		public System.Windows.Forms.MenuItem mnuMoveNow;
		public System.Windows.Forms.ToolBarButton tbrSep4;
		public System.Windows.Forms.ToolBarButton tbrThink;
        public System.Windows.Forms.MenuItem mnuThink;
		public System.Windows.Forms.MenuItem mnuEdit;
		public System.Windows.Forms.MenuItem mnuView;
		public System.Windows.Forms.MenuItem mnuFlipBoard;
		public System.Windows.Forms.MenuItem mnuPasteFEN;
		public System.Windows.Forms.MenuItem mnuSep3;
		public System.Windows.Forms.MenuItem mnuGame;
		public System.Windows.Forms.MenuItem mnuComputer;
        public System.Windows.Forms.MenuItem menuItem1;
        public ImageList imageList1;
        public MenuItem menuItem2;
        private GroupBox groupBox2;
        public TextBox anltextBox;
        public MenuItem mnuShowOpenings;
        private GroupBox groupBox3;
        public TreeView opntreeView;
        public Button savbutton;
        public Button addbutton;
        public Button bestbutton;
        public Button delbutton;
		public System.Windows.Forms.MenuItem mnuCopyFEN;

		public frmMain()
		{
			//
			// Required for Windows Form Designer support
			//
			InitializeComponent();
		}

		/// <summary>
		/// Clean up any resources being used.
		/// </summary>
		protected override void Dispose( bool disposing )
		{
			if( disposing )
			{
				if (components != null) 
				{
					components.Dispose();
				}
			}
			base.Dispose( disposing );
		}

		#region Windows Form Designer generated code
		/// <summary>
		/// Required method for Designer support - do not modify
		/// the contents of this method with the code editor.
		/// </summary>
		private void InitializeComponent()
		{
            this.components = new System.ComponentModel.Container();
            System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(frmMain));
            this.imgPieces = new System.Windows.Forms.ImageList(this.components);
            this.mnu = new System.Windows.Forms.MainMenu(this.components);
            this.mnuFile = new System.Windows.Forms.MenuItem();
            this.mnuNew = new System.Windows.Forms.MenuItem();
            this.mnuOpen = new System.Windows.Forms.MenuItem();
            this.mnuSave = new System.Windows.Forms.MenuItem();
            this.mnuSep1 = new System.Windows.Forms.MenuItem();
            this.mnuExit = new System.Windows.Forms.MenuItem();
            this.mnuEdit = new System.Windows.Forms.MenuItem();
            this.mnuUndoMove = new System.Windows.Forms.MenuItem();
            this.mnuRedoMove = new System.Windows.Forms.MenuItem();
            this.mnuUndoAllMoves = new System.Windows.Forms.MenuItem();
            this.mnuRedoAllMoves = new System.Windows.Forms.MenuItem();
            this.mnuSep2 = new System.Windows.Forms.MenuItem();
            this.mnuCopyFEN = new System.Windows.Forms.MenuItem();
            this.mnuPasteFEN = new System.Windows.Forms.MenuItem();
            this.menuItem2 = new System.Windows.Forms.MenuItem();
            this.mnuView = new System.Windows.Forms.MenuItem();
            this.mnuFlipBoard = new System.Windows.Forms.MenuItem();
            this.mnuSep3 = new System.Windows.Forms.MenuItem();
            this.mnuShowThinking = new System.Windows.Forms.MenuItem();
            this.mnuShowOpenings = new System.Windows.Forms.MenuItem();
            this.mnuGame = new System.Windows.Forms.MenuItem();
            this.mnuPausePlay = new System.Windows.Forms.MenuItem();
            this.mnuResumePlay = new System.Windows.Forms.MenuItem();
            this.mnuComputer = new System.Windows.Forms.MenuItem();
            this.mnuDifficulty = new System.Windows.Forms.MenuItem();
            this.menuItem1 = new System.Windows.Forms.MenuItem();
            this.mnuThink = new System.Windows.Forms.MenuItem();
            this.mnuMoveNow = new System.Windows.Forms.MenuItem();
            this.mnuHelp = new System.Windows.Forms.MenuItem();
            this.tbr = new System.Windows.Forms.ToolBar();
            this.tbrNew = new System.Windows.Forms.ToolBarButton();
            this.tbrOpen = new System.Windows.Forms.ToolBarButton();
            this.tbrSave = new System.Windows.Forms.ToolBarButton();
            this.tbrSep1 = new System.Windows.Forms.ToolBarButton();
            this.tbrUndoAllMoves = new System.Windows.Forms.ToolBarButton();
            this.tbrUndoMove = new System.Windows.Forms.ToolBarButton();
            this.tbrResumePlay = new System.Windows.Forms.ToolBarButton();
            this.tbrPausePlay = new System.Windows.Forms.ToolBarButton();
            this.tbrRedoMove = new System.Windows.Forms.ToolBarButton();
            this.tbrRedoAllMoves = new System.Windows.Forms.ToolBarButton();
            this.tbrSep2 = new System.Windows.Forms.ToolBarButton();
            this.tbrFlipBoard = new System.Windows.Forms.ToolBarButton();
            this.tbrSep3 = new System.Windows.Forms.ToolBarButton();
            this.tbrThink = new System.Windows.Forms.ToolBarButton();
            this.tbrSep4 = new System.Windows.Forms.ToolBarButton();
            this.tbrMoveNow = new System.Windows.Forms.ToolBarButton();
            this.imgToolMenus = new System.Windows.Forms.ImageList(this.components);
            this.pnlMain = new System.Windows.Forms.Panel();
            this.lblGamePaused = new System.Windows.Forms.Label();
            this.lvwMoveHistory = new System.Windows.Forms.ListView();
            this.lvcBlackNo = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
            this.lvcWhite = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
            this.lvcBlack = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
            this.label5 = new System.Windows.Forms.Label();
            this.label3 = new System.Windows.Forms.Label();
            this.lblPlayer = new System.Windows.Forms.Label();
            this.lblBlackClock = new System.Windows.Forms.Label();
            this.lblBlackPosition = new System.Windows.Forms.Label();
            this.lblBlackScore = new System.Windows.Forms.Label();
            this.cboIntellegenceBlack = new System.Windows.Forms.ComboBox();
            this.lblBlackPoints = new System.Windows.Forms.Label();
            this.lblWhiteClock = new System.Windows.Forms.Label();
            this.lblWhitePosition = new System.Windows.Forms.Label();
            this.lblWhiteScore = new System.Windows.Forms.Label();
            this.cboIntellegenceWhite = new System.Windows.Forms.ComboBox();
            this.lblWhitePoints = new System.Windows.Forms.Label();
            this.lblPlayerClocks = new System.Windows.Forms.Label();
            this.label2 = new System.Windows.Forms.Label();
            this.label4 = new System.Windows.Forms.Label();
            this.label1 = new System.Windows.Forms.Label();
            this.panel1 = new System.Windows.Forms.Panel();
            this.panel3 = new System.Windows.Forms.Panel();
            this.panel4 = new System.Windows.Forms.Panel();
            this.panel2 = new System.Windows.Forms.Panel();
            this.pnlEdging = new System.Windows.Forms.Panel();
            this.groupBox2 = new System.Windows.Forms.GroupBox();
            this.anltextBox = new System.Windows.Forms.TextBox();
            this.groupBox1 = new System.Windows.Forms.GroupBox();
            this.imgTiles = new System.Windows.Forms.ImageList(this.components);
            this.timer = new System.Windows.Forms.Timer(this.components);
            this.imageList1 = new System.Windows.Forms.ImageList(this.components);
            this.groupBox3 = new System.Windows.Forms.GroupBox();
            this.bestbutton = new System.Windows.Forms.Button();
            this.delbutton = new System.Windows.Forms.Button();
            this.savbutton = new System.Windows.Forms.Button();
            this.addbutton = new System.Windows.Forms.Button();
            this.opntreeView = new System.Windows.Forms.TreeView();
            this.pnlMain.SuspendLayout();
            this.groupBox2.SuspendLayout();
            this.groupBox3.SuspendLayout();
            this.SuspendLayout();
            // 
            // imgPieces
            // 
            this.imgPieces.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imgPieces.ImageStream")));
            this.imgPieces.TransparentColor = System.Drawing.Color.Transparent;
            this.imgPieces.Images.SetKeyName(0, "");
            this.imgPieces.Images.SetKeyName(1, "");
            this.imgPieces.Images.SetKeyName(2, "");
            this.imgPieces.Images.SetKeyName(3, "");
            this.imgPieces.Images.SetKeyName(4, "");
            this.imgPieces.Images.SetKeyName(5, "");
            this.imgPieces.Images.SetKeyName(6, "");
            this.imgPieces.Images.SetKeyName(7, "");
            this.imgPieces.Images.SetKeyName(8, "");
            this.imgPieces.Images.SetKeyName(9, "");
            this.imgPieces.Images.SetKeyName(10, "");
            this.imgPieces.Images.SetKeyName(11, "");
            // 
            // mnu
            // 
            this.mnu.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
            this.mnuFile,
            this.mnuEdit,
            this.mnuView,
            this.mnuGame,
            this.mnuComputer,
            this.mnuHelp});
            // 
            // mnuFile
            // 
            this.mnuFile.Index = 0;
            this.mnuFile.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
            this.mnuNew,
            this.mnuOpen,
            this.mnuSave,
            this.mnuSep1,
            this.mnuExit});
            this.mnuFile.Text = "&File";
            // 
            // mnuNew
            // 
            this.mnuNew.Index = 0;
            this.mnuNew.Shortcut = System.Windows.Forms.Shortcut.CtrlN;
            this.mnuNew.Text = "&New";
            // 
            // mnuOpen
            // 
            this.mnuOpen.Index = 1;
            this.mnuOpen.Shortcut = System.Windows.Forms.Shortcut.CtrlO;
            this.mnuOpen.Text = "&Open...";
            // 
            // mnuSave
            // 
            this.mnuSave.Index = 2;
            this.mnuSave.Shortcut = System.Windows.Forms.Shortcut.CtrlS;
            this.mnuSave.Text = "Save &As...";
            // 
            // mnuSep1
            // 
            this.mnuSep1.Index = 3;
            this.mnuSep1.Text = "-";
            // 
            // mnuExit
            // 
            this.mnuExit.Index = 4;
            this.mnuExit.Text = "E&xit";
            // 
            // mnuEdit
            // 
            this.mnuEdit.Index = 1;
            this.mnuEdit.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
            this.mnuUndoMove,
            this.mnuRedoMove,
            this.mnuUndoAllMoves,
            this.mnuRedoAllMoves,
            this.mnuSep2,
            this.mnuCopyFEN,
            this.mnuPasteFEN,
            this.menuItem2});
            this.mnuEdit.Text = "&Edit";
            // 
            // mnuUndoMove
            // 
            this.mnuUndoMove.Index = 0;
            this.mnuUndoMove.Shortcut = System.Windows.Forms.Shortcut.CtrlZ;
            this.mnuUndoMove.Text = "&Undo Move";
            // 
            // mnuRedoMove
            // 
            this.mnuRedoMove.Index = 1;
            this.mnuRedoMove.Shortcut = System.Windows.Forms.Shortcut.CtrlY;
            this.mnuRedoMove.Text = "&Redo Move";
            // 
            // mnuUndoAllMoves
            // 
            this.mnuUndoAllMoves.Index = 2;
            this.mnuUndoAllMoves.Text = "U&ndo All Moves";
            // 
            // mnuRedoAllMoves
            // 
            this.mnuRedoAllMoves.Index = 3;
            this.mnuRedoAllMoves.Text = "Re&do All Moves";
            // 
            // mnuSep2
            // 
            this.mnuSep2.Index = 4;
            this.mnuSep2.Text = "-";
            // 
            // mnuCopyFEN
            // 
            this.mnuCopyFEN.Index = 5;
            this.mnuCopyFEN.Shortcut = System.Windows.Forms.Shortcut.CtrlC;
            this.mnuCopyFEN.Text = "&Copy FEN Position";
            // 
            // mnuPasteFEN
            // 
            this.mnuPasteFEN.Index = 6;
            this.mnuPasteFEN.Shortcut = System.Windows.Forms.Shortcut.CtrlV;
            this.mnuPasteFEN.Text = "&Paste FEN Position";
            // 
            // menuItem2
            // 
            this.menuItem2.Index = 7;
            this.menuItem2.Text = "-";
            // 
            // mnuView
            // 
            this.mnuView.Index = 2;
            this.mnuView.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
            this.mnuFlipBoard,
            this.mnuSep3,
            this.mnuShowThinking,
            this.mnuShowOpenings});
            this.mnuView.Text = "&View";
            // 
            // mnuFlipBoard
            // 
            this.mnuFlipBoard.Index = 0;
            this.mnuFlipBoard.Text = "&Flip Board";
            // 
            // mnuSep3
            // 
            this.mnuSep3.Index = 1;
            this.mnuSep3.Text = "-";
            // 
            // mnuShowThinking
            // 
            this.mnuShowThinking.Index = 2;
            this.mnuShowThinking.Text = "&Show Thinking";
            // 
            // mnuShowOpenings
            // 
            this.mnuShowOpenings.Index = 3;
            this.mnuShowOpenings.Text = "Show Openings";
            // 
            // mnuGame
            // 
            this.mnuGame.Index = 3;
            this.mnuGame.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
            this.mnuPausePlay,
            this.mnuResumePlay});
            this.mnuGame.Text = "&Game";
            // 
            // mnuPausePlay
            // 
            this.mnuPausePlay.Enabled = false;
            this.mnuPausePlay.Index = 0;
            this.mnuPausePlay.Text = "&Pause Game";
            // 
            // mnuResumePlay
            // 
            this.mnuResumePlay.Index = 1;
            this.mnuResumePlay.Text = "&Resume Game";
            // 
            // mnuComputer
            // 
            this.mnuComputer.Index = 4;
            this.mnuComputer.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
            this.mnuDifficulty,
            this.menuItem1,
            this.mnuThink,
            this.mnuMoveNow});
            this.mnuComputer.Text = "&Computer";
            // 
            // mnuDifficulty
            // 
            this.mnuDifficulty.Index = 0;
            this.mnuDifficulty.Shortcut = System.Windows.Forms.Shortcut.CtrlD;
            this.mnuDifficulty.Text = "&Difficulty...";
            // 
            // menuItem1
            // 
            this.menuItem1.Index = 1;
            this.menuItem1.Text = "-";
            // 
            // mnuThink
            // 
            this.mnuThink.Index = 2;
            this.mnuThink.Shortcut = System.Windows.Forms.Shortcut.CtrlT;
            this.mnuThink.Text = "&Think";
            // 
            // mnuMoveNow
            // 
            this.mnuMoveNow.Index = 3;
            this.mnuMoveNow.Shortcut = System.Windows.Forms.Shortcut.CtrlM;
            this.mnuMoveNow.Text = "&Move Now";
            // 
            // mnuHelp
            // 
            this.mnuHelp.Index = 5;
            this.mnuHelp.Text = "&Help";
            // 
            // tbr
            // 
            this.tbr.Appearance = System.Windows.Forms.ToolBarAppearance.Flat;
            this.tbr.Buttons.AddRange(new System.Windows.Forms.ToolBarButton[] {
            this.tbrNew,
            this.tbrOpen,
            this.tbrSave,
            this.tbrSep1,
            this.tbrUndoAllMoves,
            this.tbrUndoMove,
            this.tbrResumePlay,
            this.tbrPausePlay,
            this.tbrRedoMove,
            this.tbrRedoAllMoves,
            this.tbrSep2,
            this.tbrFlipBoard,
            this.tbrSep3,
            this.tbrThink,
            this.tbrSep4,
            this.tbrMoveNow});
            this.tbr.DropDownArrows = true;
            this.tbr.ImageList = this.imgToolMenus;
            this.tbr.Location = new System.Drawing.Point(0, 0);
            this.tbr.Name = "tbr";
            this.tbr.ShowToolTips = true;
            this.tbr.Size = new System.Drawing.Size(993, 28);
            this.tbr.TabIndex = 32;
            this.tbr.TextAlign = System.Windows.Forms.ToolBarTextAlign.Right;
            this.tbr.Wrappable = false;
            // 
            // tbrNew
            // 
            this.tbrNew.ImageIndex = 0;
            this.tbrNew.Name = "tbrNew";
            this.tbrNew.Tag = "New";
            this.tbrNew.ToolTipText = "Start a new chess game";
            // 
            // tbrOpen
            // 
            this.tbrOpen.ImageIndex = 1;
            this.tbrOpen.Name = "tbrOpen";
            this.tbrOpen.Tag = "Open";
            this.tbrOpen.ToolTipText = "Open a saved chess game";
            // 
            // tbrSave
            // 
            this.tbrSave.ImageIndex = 2;
            this.tbrSave.Name = "tbrSave";
            this.tbrSave.Tag = "Save";
            this.tbrSave.ToolTipText = "Save the current chess game";
            // 
            // tbrSep1
            // 
            this.tbrSep1.Name = "tbrSep1";
            this.tbrSep1.Style = System.Windows.Forms.ToolBarButtonStyle.Separator;
            // 
            // tbrUndoAllMoves
            // 
            this.tbrUndoAllMoves.ImageIndex = 6;
            this.tbrUndoAllMoves.Name = "tbrUndoAllMoves";
            this.tbrUndoAllMoves.Tag = "UndoAllMoves";
            this.tbrUndoAllMoves.ToolTipText = "Undo all moves played so far";
            // 
            // tbrUndoMove
            // 
            this.tbrUndoMove.ImageIndex = 4;
            this.tbrUndoMove.Name = "tbrUndoMove";
            this.tbrUndoMove.Tag = "UndoMove";
            this.tbrUndoMove.ToolTipText = "Undo the last move";
            // 
            // tbrResumePlay
            // 
            this.tbrResumePlay.ImageIndex = 8;
            this.tbrResumePlay.Name = "tbrResumePlay";
            this.tbrResumePlay.Tag = "ResumePlay";
            this.tbrResumePlay.ToolTipText = "Resume play";
            // 
            // tbrPausePlay
            // 
            this.tbrPausePlay.Enabled = false;
            this.tbrPausePlay.ImageIndex = 9;
            this.tbrPausePlay.Name = "tbrPausePlay";
            this.tbrPausePlay.Tag = "PausePlay";
            this.tbrPausePlay.ToolTipText = "Pause play";
            // 
            // tbrRedoMove
            // 
            this.tbrRedoMove.ImageIndex = 5;
            this.tbrRedoMove.Name = "tbrRedoMove";
            this.tbrRedoMove.Tag = "RedoMove";
            this.tbrRedoMove.ToolTipText = "Redo move";
            // 
            // tbrRedoAllMoves
            // 
            this.tbrRedoAllMoves.ImageIndex = 7;
            this.tbrRedoAllMoves.Name = "tbrRedoAllMoves";
            this.tbrRedoAllMoves.Tag = "RedoAllMoves";
            this.tbrRedoAllMoves.ToolTipText = "Redo all moves";
            // 
            // tbrSep2
            // 
            this.tbrSep2.Name = "tbrSep2";
            this.tbrSep2.Style = System.Windows.Forms.ToolBarButtonStyle.Separator;
            // 
            // tbrFlipBoard
            // 
            this.tbrFlipBoard.ImageIndex = 10;
            this.tbrFlipBoard.Name = "tbrFlipBoard";
            this.tbrFlipBoard.Tag = "FlipBoard";
            this.tbrFlipBoard.Text = "Flip Board";
            // 
            // tbrSep3
            // 
            this.tbrSep3.Name = "tbrSep3";
            this.tbrSep3.Style = System.Windows.Forms.ToolBarButtonStyle.Separator;
            // 
            // tbrThink
            // 
            this.tbrThink.ImageIndex = 3;
            this.tbrThink.Name = "tbrThink";
            this.tbrThink.Tag = "Think";
            this.tbrThink.Text = "Think";
            this.tbrThink.ToolTipText = "Make the computer play the next move";
            // 
            // tbrSep4
            // 
            this.tbrSep4.Name = "tbrSep4";
            this.tbrSep4.Style = System.Windows.Forms.ToolBarButtonStyle.Separator;
            // 
            // tbrMoveNow
            // 
            this.tbrMoveNow.ImageIndex = 11;
            this.tbrMoveNow.Name = "tbrMoveNow";
            this.tbrMoveNow.Tag = "MoveNow";
            this.tbrMoveNow.Text = "Move Now";
            this.tbrMoveNow.ToolTipText = "Make the computer immediately play the best move it has found so far";
            // 
            // imgToolMenus
            // 
            this.imgToolMenus.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imgToolMenus.ImageStream")));
            this.imgToolMenus.TransparentColor = System.Drawing.Color.Transparent;
            this.imgToolMenus.Images.SetKeyName(0, "");
            this.imgToolMenus.Images.SetKeyName(1, "");
            this.imgToolMenus.Images.SetKeyName(2, "");
            this.imgToolMenus.Images.SetKeyName(3, "");
            this.imgToolMenus.Images.SetKeyName(4, "");
            this.imgToolMenus.Images.SetKeyName(5, "");
            this.imgToolMenus.Images.SetKeyName(6, "");
            this.imgToolMenus.Images.SetKeyName(7, "");
            this.imgToolMenus.Images.SetKeyName(8, "");
            this.imgToolMenus.Images.SetKeyName(9, "");
            this.imgToolMenus.Images.SetKeyName(10, "");
            this.imgToolMenus.Images.SetKeyName(11, "");
            // 
            // pnlMain
            // 
            this.pnlMain.BackColor = System.Drawing.Color.Transparent;
            this.pnlMain.Controls.Add(this.lblGamePaused);
            this.pnlMain.Controls.Add(this.lvwMoveHistory);
            this.pnlMain.Controls.Add(this.label5);
            this.pnlMain.Controls.Add(this.label3);
            this.pnlMain.Controls.Add(this.lblPlayer);
            this.pnlMain.Controls.Add(this.lblBlackClock);
            this.pnlMain.Controls.Add(this.lblBlackPosition);
            this.pnlMain.Controls.Add(this.lblBlackScore);
            this.pnlMain.Controls.Add(this.cboIntellegenceBlack);
            this.pnlMain.Controls.Add(this.lblBlackPoints);
            this.pnlMain.Controls.Add(this.lblWhiteClock);
            this.pnlMain.Controls.Add(this.lblWhitePosition);
            this.pnlMain.Controls.Add(this.lblWhiteScore);
            this.pnlMain.Controls.Add(this.cboIntellegenceWhite);
            this.pnlMain.Controls.Add(this.lblWhitePoints);
            this.pnlMain.Controls.Add(this.lblPlayerClocks);
            this.pnlMain.Controls.Add(this.label2);
            this.pnlMain.Controls.Add(this.label4);
            this.pnlMain.Controls.Add(this.label1);
            this.pnlMain.Controls.Add(this.panel1);
            this.pnlMain.Controls.Add(this.panel3);
            this.pnlMain.Controls.Add(this.panel4);
            this.pnlMain.Controls.Add(this.panel2);
            this.pnlMain.Controls.Add(this.pnlEdging);
            this.pnlMain.Controls.Add(this.groupBox2);
            this.pnlMain.Location = new System.Drawing.Point(0, 26);
            this.pnlMain.Name = "pnlMain";
            this.pnlMain.Size = new System.Drawing.Size(690, 505);
            this.pnlMain.TabIndex = 33;
            // 
            // lblGamePaused
            // 
            this.lblGamePaused.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, ((System.Drawing.FontStyle)((System.Drawing.FontStyle.Bold | System.Drawing.FontStyle.Italic))), System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.lblGamePaused.Location = new System.Drawing.Point(40, 168);
            this.lblGamePaused.Name = "lblGamePaused";
            this.lblGamePaused.Size = new System.Drawing.Size(320, 24);
            this.lblGamePaused.TabIndex = 141;
            this.lblGamePaused.Text = "Game Paused";
            this.lblGamePaused.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            this.lblGamePaused.Visible = false;
            // 
            // lvwMoveHistory
            // 
            this.lvwMoveHistory.BackColor = System.Drawing.SystemColors.Control;
            this.lvwMoveHistory.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
            this.lvcBlackNo,
            this.lvcWhite,
            this.lvcBlack});
            this.lvwMoveHistory.Location = new System.Drawing.Point(400, 176);
            this.lvwMoveHistory.Name = "lvwMoveHistory";
            this.lvwMoveHistory.Size = new System.Drawing.Size(248, 128);
            this.lvwMoveHistory.TabIndex = 39;
            this.lvwMoveHistory.UseCompatibleStateImageBehavior = false;
            this.lvwMoveHistory.View = System.Windows.Forms.View.Details;
            // 
            // lvcBlackNo
            // 
            this.lvcBlackNo.Text = "#";
            this.lvcBlackNo.Width = 19;
            // 
            // lvcWhite
            // 
            this.lvcWhite.Text = "White";
            this.lvcWhite.Width = 100;
            // 
            // lvcBlack
            // 
            this.lvcBlack.Text = "Black";
            this.lvcBlack.Width = 100;
            // 
            // label5
            // 
            this.label5.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.label5.Location = new System.Drawing.Point(552, 8);
            this.label5.Name = "label5";
            this.label5.Size = new System.Drawing.Size(96, 23);
            this.label5.TabIndex = 136;
            this.label5.Text = "Black";
            this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // label3
            // 
            this.label3.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.label3.Location = new System.Drawing.Point(448, 8);
            this.label3.Name = "label3";
            this.label3.Size = new System.Drawing.Size(96, 23);
            this.label3.TabIndex = 135;
            this.label3.Text = "White";
            this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // lblPlayer
            // 
            this.lblPlayer.BackColor = System.Drawing.Color.Transparent;
            this.lblPlayer.Location = new System.Drawing.Point(392, 32);
            this.lblPlayer.Name = "lblPlayer";
            this.lblPlayer.Size = new System.Drawing.Size(48, 24);
            this.lblPlayer.TabIndex = 131;
            this.lblPlayer.Text = "Player";
            this.lblPlayer.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // lblBlackClock
            // 
            this.lblBlackClock.BackColor = System.Drawing.Color.Transparent;
            this.lblBlackClock.CausesValidation = false;
            this.lblBlackClock.ForeColor = System.Drawing.Color.Black;
            this.lblBlackClock.Location = new System.Drawing.Point(552, 64);
            this.lblBlackClock.Name = "lblBlackClock";
            this.lblBlackClock.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.lblBlackClock.Size = new System.Drawing.Size(96, 23);
            this.lblBlackClock.TabIndex = 130;
            this.lblBlackClock.Text = ":";
            this.lblBlackClock.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // lblBlackPosition
            // 
            this.lblBlackPosition.BackColor = System.Drawing.Color.Transparent;
            this.lblBlackPosition.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
            this.lblBlackPosition.CausesValidation = false;
            this.lblBlackPosition.Location = new System.Drawing.Point(552, 144);
            this.lblBlackPosition.Name = "lblBlackPosition";
            this.lblBlackPosition.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.lblBlackPosition.Size = new System.Drawing.Size(96, 23);
            this.lblBlackPosition.TabIndex = 128;
            this.lblBlackPosition.Text = "0";
            this.lblBlackPosition.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // lblBlackScore
            // 
            this.lblBlackScore.BackColor = System.Drawing.Color.Transparent;
            this.lblBlackScore.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
            this.lblBlackScore.CausesValidation = false;
            this.lblBlackScore.Location = new System.Drawing.Point(552, 96);
            this.lblBlackScore.Name = "lblBlackScore";
            this.lblBlackScore.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.lblBlackScore.Size = new System.Drawing.Size(96, 23);
            this.lblBlackScore.TabIndex = 127;
            this.lblBlackScore.Text = "0";
            this.lblBlackScore.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // cboIntellegenceBlack
            // 
            this.cboIntellegenceBlack.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
            this.cboIntellegenceBlack.Items.AddRange(new object[] {
            "Human",
            "Computer"});
            this.cboIntellegenceBlack.Location = new System.Drawing.Point(552, 32);
            this.cboIntellegenceBlack.Name = "cboIntellegenceBlack";
            this.cboIntellegenceBlack.Size = new System.Drawing.Size(96, 21);
            this.cboIntellegenceBlack.TabIndex = 126;
            // 
            // lblBlackPoints
            // 
            this.lblBlackPoints.BackColor = System.Drawing.Color.Transparent;
            this.lblBlackPoints.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
            this.lblBlackPoints.CausesValidation = false;
            this.lblBlackPoints.Location = new System.Drawing.Point(552, 120);
            this.lblBlackPoints.Name = "lblBlackPoints";
            this.lblBlackPoints.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.lblBlackPoints.Size = new System.Drawing.Size(96, 23);
            this.lblBlackPoints.TabIndex = 125;
            this.lblBlackPoints.Text = "0";
            this.lblBlackPoints.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // lblWhiteClock
            // 
            this.lblWhiteClock.BackColor = System.Drawing.Color.Transparent;
            this.lblWhiteClock.CausesValidation = false;
            this.lblWhiteClock.ForeColor = System.Drawing.Color.Black;
            this.lblWhiteClock.Location = new System.Drawing.Point(448, 64);
            this.lblWhiteClock.Name = "lblWhiteClock";
            this.lblWhiteClock.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.lblWhiteClock.Size = new System.Drawing.Size(96, 23);
            this.lblWhiteClock.TabIndex = 124;
            this.lblWhiteClock.Text = ":";
            this.lblWhiteClock.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // lblWhitePosition
            // 
            this.lblWhitePosition.BackColor = System.Drawing.Color.Transparent;
            this.lblWhitePosition.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
            this.lblWhitePosition.CausesValidation = false;
            this.lblWhitePosition.Location = new System.Drawing.Point(448, 144);
            this.lblWhitePosition.Name = "lblWhitePosition";
            this.lblWhitePosition.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.lblWhitePosition.Size = new System.Drawing.Size(96, 23);
            this.lblWhitePosition.TabIndex = 122;
            this.lblWhitePosition.Text = "0";
            this.lblWhitePosition.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // lblWhiteScore
            // 
            this.lblWhiteScore.BackColor = System.Drawing.Color.Transparent;
            this.lblWhiteScore.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
            this.lblWhiteScore.CausesValidation = false;
            this.lblWhiteScore.Location = new System.Drawing.Point(448, 96);
            this.lblWhiteScore.Name = "lblWhiteScore";
            this.lblWhiteScore.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.lblWhiteScore.Size = new System.Drawing.Size(96, 23);
            this.lblWhiteScore.TabIndex = 121;
            this.lblWhiteScore.Text = "0";
            this.lblWhiteScore.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // cboIntellegenceWhite
            // 
            this.cboIntellegenceWhite.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
            this.cboIntellegenceWhite.Items.AddRange(new object[] {
            "Human",
            "Computer"});
            this.cboIntellegenceWhite.Location = new System.Drawing.Point(448, 32);
            this.cboIntellegenceWhite.Name = "cboIntellegenceWhite";
            this.cboIntellegenceWhite.Size = new System.Drawing.Size(96, 21);
            this.cboIntellegenceWhite.TabIndex = 120;
            // 
            // lblWhitePoints
            // 
            this.lblWhitePoints.BackColor = System.Drawing.Color.Transparent;
            this.lblWhitePoints.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
            this.lblWhitePoints.CausesValidation = false;
            this.lblWhitePoints.Location = new System.Drawing.Point(448, 120);
            this.lblWhitePoints.Name = "lblWhitePoints";
            this.lblWhitePoints.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.lblWhitePoints.Size = new System.Drawing.Size(96, 23);
            this.lblWhitePoints.TabIndex = 119;
            this.lblWhitePoints.Text = "0";
            this.lblWhitePoints.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // lblPlayerClocks
            // 
            this.lblPlayerClocks.BackColor = System.Drawing.Color.Transparent;
            this.lblPlayerClocks.Location = new System.Drawing.Point(392, 64);
            this.lblPlayerClocks.Name = "lblPlayerClocks";
            this.lblPlayerClocks.Size = new System.Drawing.Size(48, 24);
            this.lblPlayerClocks.TabIndex = 118;
            this.lblPlayerClocks.Text = "Clock";
            this.lblPlayerClocks.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // label2
            // 
            this.label2.BackColor = System.Drawing.Color.Transparent;
            this.label2.Location = new System.Drawing.Point(392, 144);
            this.label2.Name = "label2";
            this.label2.Size = new System.Drawing.Size(48, 24);
            this.label2.TabIndex = 116;
            this.label2.Text = "Position";
            this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // label4
            // 
            this.label4.BackColor = System.Drawing.Color.Transparent;
            this.label4.Location = new System.Drawing.Point(400, 96);
            this.label4.Name = "label4";
            this.label4.Size = new System.Drawing.Size(40, 24);
            this.label4.TabIndex = 115;
            this.label4.Text = "Score";
            this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // label1
            // 
            this.label1.BackColor = System.Drawing.Color.Transparent;
            this.label1.Location = new System.Drawing.Point(400, 120);
            this.label1.Name = "label1";
            this.label1.Size = new System.Drawing.Size(40, 24);
            this.label1.TabIndex = 114;
            this.label1.Text = "Points";
            this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // panel1
            // 
            this.panel1.BackColor = System.Drawing.Color.Black;
            this.panel1.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("panel1.BackgroundImage")));
            this.panel1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
            this.panel1.Location = new System.Drawing.Point(32, 350);
            this.panel1.Name = "panel1";
            this.panel1.Size = new System.Drawing.Size(342, 8);
            this.panel1.TabIndex = 55;
            // 
            // panel3
            // 
            this.panel3.BackColor = System.Drawing.Color.Black;
            this.panel3.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("panel3.BackgroundImage")));
            this.panel3.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
            this.panel3.Location = new System.Drawing.Point(366, 6);
            this.panel3.Name = "panel3";
            this.panel3.Size = new System.Drawing.Size(8, 352);
            this.panel3.TabIndex = 57;
            // 
            // panel4
            // 
            this.panel4.BackColor = System.Drawing.Color.Black;
            this.panel4.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("panel4.BackgroundImage")));
            this.panel4.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
            this.panel4.Location = new System.Drawing.Point(24, 6);
            this.panel4.Name = "panel4";
            this.panel4.Size = new System.Drawing.Size(342, 8);
            this.panel4.TabIndex = 58;
            // 
            // panel2
            // 
            this.panel2.BackColor = System.Drawing.Color.Black;
            this.panel2.BackgroundImage = ((System.Drawing.Image)(resources.GetObject("panel2.BackgroundImage")));
            this.panel2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
            this.panel2.Location = new System.Drawing.Point(24, 8);
            this.panel2.Name = "panel2";
            this.panel2.Size = new System.Drawing.Size(8, 350);
            this.panel2.TabIndex = 56;
            // 
            // pnlEdging
            // 
            this.pnlEdging.BackColor = System.Drawing.SystemColors.Control;
            this.pnlEdging.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
            this.pnlEdging.Location = new System.Drawing.Point(28, 12);
            this.pnlEdging.Name = "pnlEdging";
            this.pnlEdging.Size = new System.Drawing.Size(340, 340);
            this.pnlEdging.TabIndex = 35;
            // 
            // groupBox2
            // 
            this.groupBox2.Controls.Add(this.anltextBox);
            this.groupBox2.Location = new System.Drawing.Point(24, 384);
            this.groupBox2.Name = "groupBox2";
            this.groupBox2.Size = new System.Drawing.Size(639, 106);
            this.groupBox2.TabIndex = 143;
            this.groupBox2.TabStop = false;
            this.groupBox2.Text = "Analysis";
            // 
            // anltextBox
            // 
            this.anltextBox.Location = new System.Drawing.Point(8, 19);
            this.anltextBox.Multiline = true;
            this.anltextBox.Name = "anltextBox";
            this.anltextBox.ScrollBars = System.Windows.Forms.ScrollBars.Both;
            this.anltextBox.Size = new System.Drawing.Size(625, 81);
            this.anltextBox.TabIndex = 143;
            // 
            // groupBox1
            // 
            this.groupBox1.BackColor = System.Drawing.Color.Transparent;
            this.groupBox1.Location = new System.Drawing.Point(0, 21);
            this.groupBox1.Name = "groupBox1";
            this.groupBox1.Size = new System.Drawing.Size(800, 8);
            this.groupBox1.TabIndex = 34;
            this.groupBox1.TabStop = false;
            // 
            // imgTiles
            // 
            this.imgTiles.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imgTiles.ImageStream")));
            this.imgTiles.TransparentColor = System.Drawing.Color.Transparent;
            this.imgTiles.Images.SetKeyName(0, "");
            this.imgTiles.Images.SetKeyName(1, "");
            // 
            // timer
            // 
            this.timer.Interval = 333;
            // 
            // imageList1
            // 
            this.imageList1.ColorDepth = System.Windows.Forms.ColorDepth.Depth8Bit;
            this.imageList1.ImageSize = new System.Drawing.Size(16, 16);
            this.imageList1.TransparentColor = System.Drawing.Color.Transparent;
            // 
            // groupBox3
            // 
            this.groupBox3.Controls.Add(this.bestbutton);
            this.groupBox3.Controls.Add(this.delbutton);
            this.groupBox3.Controls.Add(this.savbutton);
            this.groupBox3.Controls.Add(this.addbutton);
            this.groupBox3.Controls.Add(this.opntreeView);
            this.groupBox3.Location = new System.Drawing.Point(712, 32);
            this.groupBox3.Name = "groupBox3";
            this.groupBox3.Size = new System.Drawing.Size(257, 442);
            this.groupBox3.TabIndex = 35;
            this.groupBox3.TabStop = false;
            this.groupBox3.Text = "Openings";
            // 
            // bestbutton
            // 
            this.bestbutton.Location = new System.Drawing.Point(171, 378);
            this.bestbutton.Name = "bestbutton";
            this.bestbutton.Size = new System.Drawing.Size(49, 23);
            this.bestbutton.TabIndex = 4;
            this.bestbutton.Text = "Best";
            this.bestbutton.UseVisualStyleBackColor = true;
            // 
            // delbutton
            // 
            this.delbutton.Location = new System.Drawing.Point(61, 378);
            this.delbutton.Name = "delbutton";
            this.delbutton.Size = new System.Drawing.Size(49, 23);
            this.delbutton.TabIndex = 2;
            this.delbutton.Text = "Delete";
            this.delbutton.UseVisualStyleBackColor = true;
            // 
            // savbutton
            // 
            this.savbutton.Location = new System.Drawing.Point(116, 378);
            this.savbutton.Name = "savbutton";
            this.savbutton.Size = new System.Drawing.Size(49, 23);
            this.savbutton.TabIndex = 3;
            this.savbutton.Text = "Save";
            this.savbutton.UseVisualStyleBackColor = true;
            // 
            // addbutton
            // 
            this.addbutton.Location = new System.Drawing.Point(6, 378);
            this.addbutton.Name = "addbutton";
            this.addbutton.Size = new System.Drawing.Size(49, 23);
            this.addbutton.TabIndex = 1;
            this.addbutton.Text = "Add";
            this.addbutton.UseVisualStyleBackColor = true;
            // 
            // opntreeView
            // 
            this.opntreeView.Location = new System.Drawing.Point(6, 19);
            this.opntreeView.Name = "opntreeView";
            this.opntreeView.Size = new System.Drawing.Size(245, 353);
            this.opntreeView.TabIndex = 0;
            // 
            // frmMain
            // 
            this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
            this.ClientSize = new System.Drawing.Size(993, 536);
            this.Controls.Add(this.groupBox3);
            this.Controls.Add(this.tbr);
            this.Controls.Add(this.groupBox1);
            this.Controls.Add(this.pnlMain);
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
            this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
            this.MaximizeBox = false;
            this.Menu = this.mnu;
            this.Name = "frmMain";
            this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide;
            this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
            this.Text = "F#Chess";
            this.pnlMain.ResumeLayout(false);
            this.groupBox2.ResumeLayout(false);
            this.groupBox2.PerformLayout();
            this.groupBox3.ResumeLayout(false);
            this.ResumeLayout(false);
            this.PerformLayout();

		}
		#endregion

         /// <summary>
        /// Load the m_acurPieceCursors array with the cursors that are embedded in this assembly
        /// </summary>
        public void LoadCursors()
        {
            Assembly asmMain = Assembly.GetExecutingAssembly();
            string strAsmName = asmMain.GetName().Name;
            if (strAsmName == "SharpChessUI")
            {
                strAsmName = "SharpChess"; // Fix the assembly name with regard to the executable name
            }

            // The relative pathname of an embedded resource begins with a period
            string strPath = strAsmName + ".Cursors.";

            m_acurPieceCursors[0] = new Cursor(asmMain.GetManifestResourceStream(strPath + "BlackBishop.cur"));
            m_acurPieceCursors[1] = new Cursor(asmMain.GetManifestResourceStream(strPath + "WhiteBishop.cur"));
            m_acurPieceCursors[2] = new Cursor(asmMain.GetManifestResourceStream(strPath + "BlackRook.cur"));
            m_acurPieceCursors[3] = new Cursor(asmMain.GetManifestResourceStream(strPath + "WhiteRook.cur"));
            m_acurPieceCursors[4] = new Cursor(asmMain.GetManifestResourceStream(strPath + "BlackKing.cur"));
            m_acurPieceCursors[5] = new Cursor(asmMain.GetManifestResourceStream(strPath + "WhiteKing.cur"));
            m_acurPieceCursors[6] = new Cursor(asmMain.GetManifestResourceStream(strPath + "BlackKnight.cur"));
            m_acurPieceCursors[7] = new Cursor(asmMain.GetManifestResourceStream(strPath + "WhiteKnight.cur"));
            m_acurPieceCursors[8] = new Cursor(asmMain.GetManifestResourceStream(strPath + "BlackPawn.cur"));
            m_acurPieceCursors[9] = new Cursor(asmMain.GetManifestResourceStream(strPath + "WhitePawn.cur"));
            m_acurPieceCursors[10] = new Cursor(asmMain.GetManifestResourceStream(strPath + "BlackQueen.cur"));
            m_acurPieceCursors[11] = new Cursor(asmMain.GetManifestResourceStream(strPath + "WhiteQueen.cur"));
        }


	}
}
